package net.wenku8.reader.model.book;

import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
import com.thoughtworks.xstream.annotations.XStreamConverter;
import com.thoughtworks.xstream.converters.extended.ToAttributedValueConverter;

@XStreamAlias("data")
@XStreamConverter(value= ToAttributedValueConverter.class, strings={"text"})
public class BookDataValue {

    @XStreamAsAttribute
    String name;
    @XStreamAsAttribute
    String value;
    @XStreamAsAttribute
    @XStreamAlias("aid")
    String bookId;
    @XStreamAsAttribute
    @XStreamAlias("cid")
    String chapterId;

    String text;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public String getBookId() {
        return bookId;
    }

    public void setBookId(String bookId) {
        this.bookId = bookId;
    }

    public String getChapterId() {
        return chapterId;
    }

    public void setChapterId(String chapterId) {
        this.chapterId = chapterId;
    }

    public String getText() {
        return text;
    }

    public void setText(String text) {
        this.text = text;
    }
}
